<nz-dropdown-menu #rightClickMenu="nzDropdownMenu" style="width:200px;">
  <ul nz-menu style="width:200px;">
    <li nz-menu-item (click)="openFile()">转到文件所在位置</li>
    <li nz-menu-item onclick="location.reload();">加入收藏</li>
  </ul>
</nz-dropdown-menu>

<nz-layout class="white-back">

  <nz-content class="white-back" style="margin-right: 10px">
    <nz-list nzBordered [nzLoading]="pageData.loading">
      <nz-list-header>
        <nz-row nzGutter="24">
          <nz-col nzSpan="6">名称</nz-col>
          <nz-col nzSpan="3">大小</nz-col>
          <nz-col nzSpan="4">修改日期</nz-col>
          <nz-col nzSpan="5">共享状态</nz-col>
          <nz-col nzSpan="4">拥有者id</nz-col>
        </nz-row>
      </nz-list-header>
      <nz-list-item *ngFor="let file of pageData.list" (click)="fileClick(file)" (dblclick)="openFile()"
                    (contextmenu)="contextMenu($event, rightClickMenu,file);">
        <a style="width: 100%;">
          <nz-row nzGutter="24">
            <nz-col nzSpan="6">
              <label nz-checkbox [(ngModel)]="file.checked" (change)="fileClick(file)">
                <img style="width: 20px" [src]="getImgURL(file)" alt="未知类型">
                {{file['name']}}
              </label>
            </nz-col>
            <nz-col nzSpan="3">
              {{ (file.size | nzBytes) || '-' }}
            </nz-col>
            <nz-col nzSpan="4">
              {{ file.lastModified | date:'yyyy-MM-dd HH:mm:ss'}}
            </nz-col>
            <nz-col nzSpan="5">
              <nz-tag *ngIf="file.permission?.ann?.open" nzColor="orange">ann</nz-tag>
              <nz-tag *ngIf="file.permission?.user?.open" nzColor="green">user</nz-tag>
              <nz-tag *ngIf="file.permission?.custom?.open" nzColor="blue">custom</nz-tag>
            </nz-col>
            <nz-col nzSpan="4">
              {{file.owner}}
            </nz-col>
          </nz-row>
        </a>

        <!--    <span></span>-->
        <!--    <span style="width: 180px">{{ file.lastModified | date:'yyyy-MM-dd HH:mm:ss'}}</span>-->

      </nz-list-item>
      <nz-list-empty *ngIf="pageData.list.length==0"></nz-list-empty>
      <nz-list-footer>
        <nz-pagination
          style="margin-bottom: 10px" nzPageSize="12" nzShowQuickJumper
          [(nzPageIndex)]="pageData.listPage" [nzTotal]="pageData.total" (nzPageIndexChange)="pageIndexChange()" >
        </nz-pagination>
      </nz-list-footer>
    </nz-list>
  </nz-content>
  <nz-sider nzTheme="light" nzWidth="260px" style=" margin-right: 10px">
    <bby-file-info if [checkedFiles]="checkedFile" [rootUrl]="pageService.rootUrl"
                   [path]="checkedFilePath"></bby-file-info>
  </nz-sider>
</nz-layout>

